import http from './httpInstance';

// 实时视频流
function getPointUrl(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/playruntimecameraurl',
    // url: '/integrated-workbench/v1/eventcenter/busizeventdetail/playruntimecameraurl',
    data: params,
  });
}

// 获取回放视频流
function getPointUrlBack(params) {
  return http({
    method: 'post',
    // url: '//integrated-workbench/v1/eventcenter/busizeventdetail/playRuntimeCameraUrl',
    url: '/integrated-workbench/v1/eventcenter/busizeventdetail/playbackcameraurl',
    data: params,
  });
}

// 获取点位列表
function getPointList(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/devicecombox',
    data: params,
  });
}

// 获取点位列表
function getPointListZr(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/meeting/devicemanagetree',
    data: params,
  });
}

// 获取所属社区
function getSqList(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/communitycombox',
    data: params,
  });
}

// 获取处置人员
function getczryList(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/membercombox',
    data: params,
  });
}

// 获取事件列表

function getEventList(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/busizeventlist',
    data: params,
  });
}

function getEventListld(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/busizquerylist',
    data: params,
  });
}



// 确定分派

function dispatchEvent(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/confirmassign',
    data: params,
  });
}

// 确认完成

function completeEvent(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/confirmhandle',
    data: params,
  });
}

// 查询事件详情

function getEventDetail(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/busizeventdetail',
    data: params,
  });
}

// 登录

function login(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/eventcenter/authentication/login',
    data: params,
  });
}

// 获取最新事件--外层列表

function getzxsjList(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/list',
    data: params,
  });
}

// 获取待办

function getzdbList(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/list',
    data: params,
  });
}

// 获取数据总览:队长

function getDataTotalList(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/statistics',
    data: params,
  });
}

// 获取一键取证

function getOneKeyCheck(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/oneclickevidence',
    data: params,
  });
}

// 切换回放视频

function getplaybackcameraurl60s(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/playbackcameraurl60s',
    data: params,
  });
}

// 远程喊话

function talkToseppk(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/busizeventdetail/talkurl',
    data: params,
  });
}

// 获取事件类型

function getEventTypeList(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/eventdefinecombox',
    data: params,
  });
}

// 获取处置状态

function getczztList(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/eventstatuscombox',
    data: params,
  });
}

// 获取事件等级

function getsjjdList(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/eventclasscombox',
    data: params,
  });
}

// 获取事件来源

function getslzyList(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/eventsourcecombox',
    data: params,
  });
}

// 获取巡查待办
function getxcdbList(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/publicsafety/workstation/inspecttodo',
    data: params,
  });
}

// 获取最新事件
function getzxsjdbList(params) {
  return http({
    method: 'post',
    // /integrated-workbench/v1/enforcement/list
    // url: '/integrated-workbench/v1/publicsafety/workstation/pealerttodo',
    url: '/integrated-workbench/v1/enforcement/list',
    data: params,
  });
}

// 获取最新事件
function getzxsjdbListnew(params) {
  return http({
    method: 'post',
    // /integrated-workbench/v1/enforcement/list
    // url: '/integrated-workbench/v1/publicsafety/workstation/pealerttodo',
    url: '/integrated-workbench/v1/streetleader/emergency_list',
    data: params,
  });
}

// 进度条。查看详情---下载的流
function geteventarchivingdownload(params) {
  return http({
    method: 'get',
    url: '/integrated-workbench/v1/enforcement/eventarchivingdownload',
    params: params, // 使用 params 属性传递查询参数
    responseType: 'blob', // 设置响应类型为 blob 以便处理文件流
  });
}

// 进度条。查看详情---下载的流
function geteventarchivingdownloadPost(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/eventarchivingdownload',
    data: params,
    // method: 'get',
    // url: '/integrated-workbench/v1/enforcement/eventarchivingdownload',
    // params: params, // 使用 params 属性传递查询参数
    // responseType: 'blob', // 设置响应类型为 blob 以便处理文件流
  });
}
// 进度条。查看详情---预览url
function geteventarchivingpreview(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/enforcement/eventarchivingpreview',
    data: params,
  });
}

// 执法大队的队长---获取地图的高点
function getbyuserid(params) {
  return http({
    method: 'post',
    url: '/integrated-workbench/v1/mobileapp/mob/getgps/byuserid',
    data: params,
  });
}
export {
  getzxsjdbListnew,
  getzxsjdbList,
  getxcdbList,
  getslzyList,
  getsjjdList,
  getczztList,
  getEventTypeList,
  talkToseppk,
  getOneKeyCheck,
  getDataTotalList,
  getzdbList,
  getzxsjList,
  getPointUrlBack,
  login,
  getEventDetail,
  completeEvent,
  dispatchEvent,
  getEventList,
  getEventListld,
  getczryList,
  getPointUrl,
  getPointList,
  getPointListZr,
  getSqList,
  geteventarchivingdownload,
  geteventarchivingpreview,
  geteventarchivingdownloadPost,
  getplaybackcameraurl60s,
  getbyuserid,
};
